<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
    <script src="jquery-1.8.2.min.js"></script>
</head>
<body>
    <!--<ul class="topnav">
        <li>li1</li>
        <li>li2
            <ul>
                <li>next l1</li>
                <li>next l2</li>
                <li>next l3</li>
            </ul>
        </li>
        <li>l3</li>
    </ul>-->

    <span id="prev">span1</span>
    <div>div1</div>
    <div>div2</div>
    <div>div3
        <div>div4</div>
    </div>
</body>
<script>
    $(function () {
        // $(".topnav > li").css("border","1px solid red");
        // $("li + li").css("border","1px solid red");

    })
</script>
</html>